package io.finer.erp.jeecg.bas.service.impl;

import io.finer.erp.jeecg.bas.entity.SalesDeliveryEntry;
import io.finer.erp.jeecg.bas.mapper.SalesDeliveryEntryMapper;
import io.finer.erp.jeecg.bas.service.ISalesDeliveryEntryService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;

import java.util.List;

/**
 * @Description: 发货单详情表
 * @Author: jeecg-boot
 * @Date:   2021-04-26
 * @Version: V1.0
 */
@Service
public class SalesDeliveryEntryServiceImpl extends ServiceImpl<SalesDeliveryEntryMapper, SalesDeliveryEntry> implements ISalesDeliveryEntryService {

    @Autowired
    private SalesDeliveryEntryMapper entryMapper;

    @Override
    public List<SalesDeliveryEntry> getSalesDeliveryEntryList(String code){
        return entryMapper.getDeliveryEntryByCode(code);


    }

	@Override
	public boolean updateWriteAmount(SalesDeliveryEntry salesDeliveryEntry) {
		int num = this.entryMapper.updateWriteAmount(salesDeliveryEntry);
		if(num > 0) {
			return true;
		}
		return false;
	}
}
